The present disclosure relates to electronic devices and image forming apparatuses that include flash memory having an upper limit for a number of writes thereto.
In electronic devices—in particular embedded devices—and multifunction peripherals (MFPs), electrically erasable programmable read-only memory (EEPROM) is used in order to store small volumes of data used by the device even when power to the device is cut off. Recently it has become common place to use NOR flash memory as EEPROM.
EEPROM is often used as non-volatile memory for preserving small volumes of data that are stored in volatile memory composed of dynamic random access memory (DRAM) or the like.
The following technique has for example been disclosed as an optimal technique for controlling writing of data from volatile memory to non-volatile memory. In the aforementioned technique, data is grouped for each write timing and only data to be written at a specific timing is written to the non-volatile memory, thereby reducing the amount of time required for writing.
In flash memory, erasing of data in block units (initialization) is performed prior to writing of data in page units. In consideration of the fact that flash memory has a structural upper limit for the number of times initialization can be performed (number of writes), a technique referred to as wear leveling has been disclosed in which writing is performed evenly in order to avoid intensive writing to a specific block.
Journaling Flash File System, version 2 (JFFS2) is an example of a file system for performing wear leveling that includes journaling and that is optimized for properties of NAND flash memory. JFFS2 is a file system for Linux (registered Japanese trademark) that is commonly used in embedded devices.